In the technology of digitally processing moving image data having an enormous amount of information, it is required to perform highly efficient compression processing.
FIG. 13 shows an example of an image coding device. As shown in FIG. 13, an image coding device 100 includes: a blocking portion 101 that creates a macroblock of 8*8, which is a basic unit of DCT (Discrete Cosine Transform) by executing block processing when moving image data is input; a shuffling portion 102 that collects a predetermined number of macroblocks created by the blocking portion 101 and shuffles the macroblocks in a unit of slices so as to make amounts of information consistent; a movement detection portion 103 that detects movement of the macroblock; a DCT processing portion 104 that executes weight processing by way of DCT conversion of the shuffled block for each slice on the basis of the movement detected by the movement detection portion 103; a code amount estimation portion 105 that estimates a code amount by classifying the blocks processed by the DCT processing portion 104; a quantization portion 106 that quantizes the blocks according to the code amount estimated by the code amount estimation portion 105; and a variable length coding (VLC) portion 108 that variable-length codes the slice quantized by the quantization portion 106 and outputs compressed coded data obtained by compressing an amount of information with high efficiency.
Since the macroblocks continuously created at the blocking portion 101 and output directly reflect photographed image information, a correlation is generated between adjacent macroblocks, and an error amount or data amount contained in the individual macroblocks may be concentrated in some macroblock groups. With the purpose of preventing propagation of such data error or improving a processing speed realized by dividing the processing into a plurality of processing units and simultaneously processing them with a plurality of computing units, processing may be divided into a plurality of processing units and executed in some cases even if a single image is to undergo compression processing. A processing unit capable of such independent processing is referred to as a “slice”. Thus, the shuffling portion 102 executes shuffling processing in which a spatial position of a macroblock is moved from an original position by the unit of slice obtained by collecting a plurality of macroblocks and shuffling. In this way, the correlation between the macroblocks is lowered and the data amounts between the macroblocks are evenly distributed while at the same time a concentration of an error in some macroblock groups is prevented.
The shuffling processing executed by the shuffling portion 102 conforms to the DV standard, which is a standard of digital video published by the HD Digital VCR Conference mainly for household use (See Non-patent Literatures 1 and 2). The shuffling method specified by the DV standard assumes images of predetermined sizes, namely, 720*480, 720*576, 960*720, 1280*1080, and 1440*1080. Moreover, although the shuffling portion 102 divides the image into super blocks and extracts a predetermined number of macroblocks for each super block and rearranges them, the size of the super block divided from the image is also specified.
FIG. 14 shows a structure of image data whereby the shuffling portion 102 performs shuffling according to the DV standard. Ix indicates the number of macroblocks in the horizontal direction, while Iy indicates the number of macroblocks in the vertical direction. Furthermore, the number of macroblocks in the horizontal direction in the super block divided by the shuffling portion is referred to as SBsx, and the number of macroblocks in the vertical direction in the super block as SBsy. As is evident from FIG. 14, due to the size of image processed by the shuffling portion 102 is specified, the size of the super block to be divided can also be equally allocated into SBsx in the horizontal direction and SBsy in the vertical direction.